package by.andronix.logger
{
	import mx.logging.ILoggingTarget;
	import mx.logging.targets.TraceTarget;
	
	public class LogTargetFactory
	{
		
		public static const TRACE_TARGET:String = 'traceTarget';
		public static const FIREBUG_TARGET:String = 'firebugTarget';
		public static const SCREEN_TARGET:String = 'screenTarget';
		public static const KP_PUREMVC_CONSOLE_TARGET:String = 'KP_PUREMVC_CONSOLE_TARGET';
		
		public static function create(id: String): ILoggingTarget
		{
			var target: ILoggingTarget;
			
			switch(id)
			{
				case TRACE_TARGET:
					target = new TraceTarget();
					break;	
					
				case FIREBUG_TARGET:
					target = new FirebugTarget();
					break;
					
				case SCREEN_TARGET:
					//target = new ScreenOverlayTarget();
					break;
					
				case KP_PUREMVC_CONSOLE_TARGET:
					target = new KPPureMVCConsoleTarget();
					break;
			}
			
			return target;
		}

	}
}